Eclipse Platform
Pre-release 3.0

org.eclipse.ui.contexts
Interface IContextManager

All Known Subinterfaces:
IMutableContextManager

public interface IContextManager

An instance of this interface allows clients to manage contexts, as defined by the extension point org.eclipse.ui.contexts.

This interface is not intended to be extended or implemented by clients.

EXPERIMENTAL

Since:
3.0
See Also:
ContextManagerFactory

Method Summary
 void addContextManagerListener(IContextManagerListener contextManagerListener)
          Registers an instance of IContextManagerListener to listen for changes to properties of this instance.
 IContext getContext(String contextId)
          Returns an instance of IContext given an identifier.
 Set getDefinedContextIds()
          Returns the set of identifiers to defined contexts.
 Set getEnabledContextIds()
          Returns the set of identifiers to enabled contexts.
 void removeContextManagerListener(IContextManagerListener contextManagerListener)
          Unregisters an instance of IContextManagerListener listening for changes to properties of this instance.
 

Method Detail

addContextManagerListener

public void addContextManagerListener(IContextManagerListener contextManagerListener)
Registers an instance of IContextManagerListener to listen for changes to properties of this instance.

Parameters:
contextManagerListener - the instance to register. Must not be null. If an attempt is made to register an instance which is already registered with this instance, no operation is performed.

getContext

public IContext getContext(String contextId)
Returns an instance of IContext given an identifier.

Parameters:
contextId - an identifier. Must not be null
Returns:
an instance of IContext.

getDefinedContextIds

public Set getDefinedContextIds()
Returns the set of identifiers to defined contexts.

Notification is sent to all registered listeners if this property changes.

Returns:
the set of identifiers to defined contexts. This set may be empty, but is guaranteed not to be null. If this set is not empty, it is guaranteed to only contain instances of String.

getEnabledContextIds

public Set getEnabledContextIds()
Returns the set of identifiers to enabled contexts.

Notification is sent to all registered listeners if this property changes.

Returns:
the set of identifiers to enabled contexts. This set may be empty, but is guaranteed not to be null. If this set is not empty, it is guaranteed to only contain instances of String.

removeContextManagerListener

public void removeContextManagerListener(IContextManagerListener contextManagerListener)
Unregisters an instance of IContextManagerListener listening for changes to properties of this instance.

Parameters:
contextManagerListener - the instance to unregister. Must not be null. If an attempt is made to unregister an instance which is not already registered with this instance, no operation is performed.

Eclipse Platform
Pre-release 3.0

Copyright (c) IBM Corp. and others 2000, 2003. All Rights Reserved.